<!-- $Id: htmlprogress.html 2012-04-09 wengcanvip@qq.com $ -->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>SLIDE_HOMW</title>
<link href="/css/style.css" rel="stylesheet" type="text/css" />
<link href="./css/boxy.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="./js/jquery.min.js"></script><script type="text/javascript" src="js/admin.js"></script><script type="text/javascript" src="js/jquery.boxy.js"></script>
<style type="text/css">
</style>
</head>
<body>
  <div class="list_border">
  <div class="tools" style="padding-left:230px;"></div>
  <div class="box">
      <div id="step_1">
      <form id="form2" name="form1" method="post" action="">
        <table width="936" border="1">
          <tr>
            <td width="116">序号</td>
            <td width="159">勾选后点击执行</td>
            <td width="412">对应操作</td>
            <td width="221">状态</td>
          </tr>
          <tr>
            <td>1</td>
            <td>
              <input type="checkbox" name="s1" id="s1" />
            </td>
            <td>测试</td>
            <td id="progress_1">&nbsp;</td>
          </tr>
          <tr>
            <td>2</td>
            <td>
              <input type="checkbox" name="s2" id="s2" />
            </td>
            <td>文章、文章列表、案例页面</td>
            <td id="progress_2">&nbsp;</td>
          </tr>
          <tr>
            <td>3</td>
            <td>
              <input type="checkbox" name="s3" id="s3" />
            </td>
            <td>办公家具页面</td>
            <td id="progress_3">&nbsp;</td>
          </tr>
          <tr>
            <td>4</td>
            <td>
              <input type="checkbox" name="s4" id="s4" />
            </td>
            <td>单页面</td>
            <td id="progress_4">&nbsp;</td>
          </tr>
          <tr>
            <td height="25">5</td>
            <td>
              <input type="checkbox" name="s5" id="s5" />
            </td>
            <td>首页</td>
            <td id="progress_5">&nbsp;</td>
          </tr>
        </table>
        </form>
</div>
      <div id="step_2">
      
      </div>
      <div id="step_3">
      
      </div>            
  </div>
<p style="padding: 15px; text-align: center;">
    <input type="submit" name="Button1" value="执行" id="Button1" class="add" style="font-weight:bold;width:70px;" />
 </p>
<script type="text/javascript">
var pArr=new Array();
function doGeni(i){
			$("#progress_"+pArr[i-1]).html("<img src='/images/admin/svwloader.gif'/>");
			$.getJSON("/index.php?c=admin&a=sysconfig&mod=htmlgen", {step:pArr[i-1]},function(json){
  			if(json.status==1){
				$("#progress_"+pArr[i-1]).html("<img src='/images/admin/yes.gif'/>");
				if(i++!=pArr.length){
					doGeni(i)
				}else{
					alert("恭喜！您所选定的操作已经全部完成！");	
				}	
			};
		});		
}
$(function(){
	$("input[name^='s']").click(function(){
		var currentId=parseInt($(this).attr ("name").replace('s',''));
	if($(this).attr ("checked")=="checked" ){
			pArr.push(currentId);
			$("#progress_"+currentId).html("<img src='/images/admin/clock.gif'/>");	
	}else{
		for(i in pArr)
		{
			if(currentId==pArr[i]){
				pArr.splice(i,i+1);
			$("#progress_"+currentId).html("&nbsp;");	
			}
		} 	
		}
	});	
$("#Button1").bind("click",function(){
	 pArr=pArr.sort();
	 var stepToatl=pArr.length;
	 
	 
	doGeni(1);
})	
});
</script> 
<!--WORK OF CAN.WENG jan 19th,2012-->
</body>
</html>
